#pragma once

#include "Objects.h"

#ifndef __CANVAS_EVENTS_H
#define __CANVAS_EVENTS_H


namespace Canvas 
{
	template<class T>
	class Event
	{};

	class EventHandler abstract : public Object
	{
	public:
		virtual bool IsAttached() = 0;
	};

	template<class... TArgs>
	class Event<void(TArgs...)> : public Object, private NonCopyable
	{
	protected:
		class EventHandlerImpl : public EventHandler
		{
		private:
			bool attached;
			Func<void(TArgs...)> function;
		public:
			bool IsAttached() override { return attached; }
		};
	};
}

#endif